package com.kun.valiant.course.domain.vo;

import com.kun.valiant.common.core.domain.BaseEntity;
import com.kun.valiant.common.validator.CreateGroup;
import com.kun.valiant.common.validator.EditGroup;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

/**
 * @author fangkun
 * @create 2023-06-06-16:55
 */
public class CourseVO extends BaseEntity {

    /**
     * 课程id
     */
    @NotNull(message = "课程ID不能为空", groups = {EditGroup.class})
    private Long courseId;

    /**
     * 课程类型 1 舞蹈类 2 游泳类 3 拳击类
     */
    @NotNull(message = "课程类型不能为空",groups = {CreateGroup.class,EditGroup.class})
    private Integer type;

    /**
     * 课程名称
     */
    @NotBlank(message = "{course.name.notBlank}",groups = {CreateGroup.class,EditGroup.class})
    private String name;

    /**
     * 价格
     */
    @NotNull(message = "价格不能为空",groups = {CreateGroup.class,EditGroup.class})
    @Min(value = 0,message = "无效价格")
    private BigDecimal price;

    //最低价格
    private BigDecimal minPrice;

    //最高价格
    private BigDecimal maxPrice;

    /**
     * 适用人群
     */
    @NotNull(message = "适用人群不能为空",groups = {CreateGroup.class,EditGroup.class})
    private Integer applyTo;

    /**
     * 课程描述信息
     */
    @NotBlank(message = "课程简介不能为空",groups = {CreateGroup.class,EditGroup.class})
    private String info;

    /**
     * 课程归类
     */
    private String subject;

    public Long getCourseId() {
        return courseId;
    }

    public void setCourseId(Long courseId) {
        this.courseId = courseId;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public BigDecimal getMinPrice() {
        return minPrice;
    }

    public void setMinPrice(BigDecimal minPrice) {
        this.minPrice = minPrice;
    }

    public BigDecimal getMaxPrice() {
        return maxPrice;
    }

    public void setMaxPrice(BigDecimal maxPrice) {
        this.maxPrice = maxPrice;
    }

    public Integer getApplyTo() {
        return applyTo;
    }

    public void setApplyTo(Integer applyTo) {
        this.applyTo = applyTo;
    }

    public String getInfo() {
        return info;
    }

    public void setInfo(String info) {
        this.info = info;
    }

    public String getSubject() {
        return subject;
    }

    public void setSubject(String subject) {
        this.subject = subject;
    }
}
